package com.star.bookstore.common.excoption;

public enum  CodeEnum {

    UNKNOW_EXCEPTION(1000,"系统未知异常"),
    VAILD_EXCEPTION(1001,"参数格式校验失败"),
    ILLEGAL_ACCESS_EXCEPTION(1002,"非法访问异常"),
    NULL_POINTER_EXCEPTION(1003,"空指针异常"),
    ILLEGAL_CHAR(1004,"非法字符"),
    REPEAT_EXCEPTION(1005,"数据重复异常"),
    FORMAT_EXCEPTION(1006,"错误请求异常");

    private int code;
    private String message;

    CodeEnum(int code, String message) {
        this.code = code;
        this.message = message;
    }

    public int getCode() {
        return code;
    }

    public String getMessage() {
        return message;
    }

}
